package com.dingqb.ktdemo.oop


abstract open class OopAbstact : Any() {
    open fun ff() {
        println("OopAbstact:ff")
    }
}

open class Base : OopAbstact() {
    override fun ff() {
        super.ff()
        println("Base:ff")
    }

}

interface IBase {
    fun ff() {
        println("IBase ff")
    }
}

open class Child : Base(), IBase {
    override fun ff() {
        super<Base>.ff();
        super<IBase>.ff();
        println("Child:ff")
    }

}

fun main() {
//    var child = Child()
//    child.ff()

    var base = Base();
    base.ff();


}

public open class A : Any() {
    override fun hashCode(): Int {
        return super.hashCode()
    }

    override fun toString(): String {
        return super.toString()
    }

    override fun equals(other: Any?): Boolean {
        return super.equals(other)
    }
}

class B : A() {}